package com.codemonkey.lq.extend.excelverification;

import java.util.HashMap;
import java.util.Map;

/**
 * 配置文件在内存中的对照
 * @author LQ
 *
 */
public final class Config {
	private final Map<String, Verifier> container = new HashMap<String, Verifier>(10);

	public void register(String fieldName, Verifier verifier) {
		if (container.containsKey(fieldName)) {
			return;
		}

		container.put(fieldName, verifier);
	}

	public Verifier findVerifier(String fieldName) {
		return container.get(fieldName);
	}
}
